# Contributor: Aiden Grossman <agrossman154@yahoo.com>
# Maintainer: Aiden Grossman <agrossman154@yahoo.com>
pkgname=py3-hatch-jupyter-builder
pkgver=0.8.3
pkgrel=1
pkgdesc="A hatch plugin to help build Jupyter packages"
url="https://github.com/jupyterlab/hatch-jupyter-builder"
arch="noarch"
license="BSD-3-Clause"
depends="py3-hatchling"
makedepends="py3-gpep517 py3-setuptools"
checkdepends="py3-pytest py3-tomli py3-pytest-mock"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/jupyterlab/hatch-jupyter-builder/archive/refs/tags/v$pkgver.tar.gz"
builddir="$srcdir/hatch-jupyter-builder-$pkgver"

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	pytest
}

package() {
	python3 -m installer --destdir="$pkgdir" .dist/*.whl
}

sha512sums="
047d292ad1985ee9b7908de46b40a5b340575f5f43dbe5b2eebe9d5b0b82c37181d5f2e7ece3d06abf685a45c1a007f004080cd1527922c0bf38d99ca02c587e  py3-hatch-jupyter-builder-0.8.3.tar.gz
"
